package com.sohu.peak.gallery.domain;

import java.util.Date;

import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang.time.DateUtils;

public class Orign implements java.io.Serializable {

	// Fields

	private Long id;
	private String name;
	private String desc;
	private String url;
	private String logo;
	private Date ctime;
	private Integer status;

	// Constructors

	public Orign() {
	}
	public Orign(String name, String desc, Integer status) {
		this.name = name;
		this.desc = desc;
		this.status = status;
	}

	// Property accessors

	public Long getId() {
		return this.id;
	}

	public void setId(Long id) {
		this.id = id;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getDesc() {
		return desc;
	}

	public void setDesc(String desc) {
		this.desc = desc;
	}

	public Integer getStatus() {
		return status;
	}

	public void setStatus(Integer status) {
		this.status = status;
	}

	public String getUrl() {
		return url;
	}

	public void setUrl(String url) {
		this.url = url;
	}

	public String getLogo() {
		return logo;
	}

	public void setLogo(String logo) {
		this.logo = logo;
	}

	public Date getCtime() {
		return ctime;
	}

	public void setCtime(Date ctime) {
		this.ctime = ctime;
	}

	public boolean equalsIgnoreId(Orign o2) {
		return o2 != null && (StringUtils.equals(this.name, o2.name)
				&& StringUtils.equals(this.desc, o2.desc)
				&& StringUtils.equals(this.url, o2.url)
				&& StringUtils.equals(this.logo, o2.logo)
				&& this.status.equals(o2.status) 
				&& this.ctime == null ? o2.ctime == null
				: this.ctime.getTime() == o2.ctime.getTime());
	}
}